 |
|
 |
Subject: dojo.xhrGet and response data |
 |
 |
 |
Product Area: Domino Server |
 |
Technical Area: Application Development |
 |
Platform: ALL |
 |
Release: 8.5.2 |
 |
Reproducible: Not applicable |
 |
 |
 |
 |
Hi,
I'm new to dojo and have set up some javascript to get values from a Notes agent.
function getData(agentName) {
//The parameters to pass to xhrGet, the url, how to handle it, and the callbacks.
var xhrArgs = {
url: DBurl+ "/" + agentName,
handleAs: "text",
load: function(response, ioArgs) {
alert("response= " +response);
retVal = response;
},
error: function(response, ioArgs) {
console.error("HTTP status code: ", ioArgs.xhr.status);
alert(response);
}
}
//Call the asynchronous xhrGet
var deferred = dojo.xhrGet(xhrArgs);
}
The function works and returns data from my agent, however. The agent has a print statement as follows:
Print "<OPTION>SELECT</OPTION>"
however, the response text reads:
"<html>
<head>
</head>
<body text="#000000">
<OPTION>SELECT</OPTION>
</body>
</html>"
Am I doing something wrong? Can I just return the bit I set in the print statement? or is this standard and I just need to strip away the extranious tags?
 
Feedback number WEBB8DF3XN created by ~Ned Dwoatexakol on 01/25/2011

Status: Open
Comments:

dojo.xhrGet and response data (~Ned Dwoatexako... 25.Jan.11)
. . set content type (~Evelyn Desjumi... 25.Jan.11) |
|  |
|